Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Slash help command #5

Draft
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

DenverCoder1
Copy link
Collaborator

@DenverCoder1 DenverCoder1 commented Jul 27, 2022

Summary

Adds SlashHelpCommand base class and a MinimalSlashHelpCommand that implements it.

Docs: https://nextcord-ext-help-commands--5.org.readthedocs.build/en/5/

Usage

from nextcord.ext.help_commands import MinimalSlashHelpCommand

# bot = nextcord.Client(...) or bot = commands.Bot(...) etc.

MinimalSlashHelpCommand().add_to_client(bot)
  • Command list as option
  • Cog support
  • Support for subcommands (similar to command groups)
  • Embed Slash Help command (may be another PR)

Installation for testing

pip install -U git+https://github.com/DenverCoderOne/nextcord-ext-help-commands.git@slash-help

Checklist

  • If code changes were made then they have been tested.
    • I have updated the documentation to reflect the changes.
    • I have run task pyright and fixed the relevant issues.
  • This PR fixes an issue.
  • This PR adds something new (e.g. new method or parameters).
  • This PR is a breaking change (e.g. methods or parameters removed/renamed)
  • This PR is not a code change (e.g. documentation, README, ...)

@DenverCoder1 DenverCoder1 added p: medium Priority: medium - should be worked on in the near future s: in progress Status: the issue or PR is in development/progress t: enhancement Type: enhancement - new feature or request labels Jul 27, 2022
@lol219
Copy link

lol219 commented Nov 1, 2022

When merging this @DenverCoder1

@ooliver1
Copy link
Member

ooliver1 commented Nov 1, 2022

When it is ready. It is still a draft, you can use a git branch with pip install git+url if you really need this.

@lol219
Copy link

lol219 commented Nov 1, 2022

When it is ready. It is still a draft, you can use a git branch with pip install git+url if you really need this.

Thanks

@DenverCoder1
Copy link
Collaborator Author

Yep, I believe it would be pip install git+https://github.com/DenverCoderOne/nextcord-ext-help-commands.git@slash-help

Feel free to let me know if there are any issues. Sorry I haven't gotten around to doing much testing on this lately.

@lol219
Copy link

lol219 commented Nov 1, 2022

Is there any way to make the slash cmds show in embed description using this PR

@DenverCoder1
Copy link
Collaborator Author

You'd currently need to subclass SlashHelpCommand or MinimalSlashHelpCommand and override the methods you want to change (similar to EmbeddedHelpCommand, but subclassing a Slash one instead of an ext commands one).

@lol219
Copy link

lol219 commented Nov 1, 2022

I see ,thanks!

@DenverCoder1
Copy link
Collaborator Author

DenverCoder1 commented Nov 1, 2022

An ext.help_commands implementation will come eventually though. Maybe not in this PR, but it is definitely planned.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p: medium Priority: medium - should be worked on in the near future s: in progress Status: the issue or PR is in development/progress t: enhancement Type: enhancement - new feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants